﻿using System;

namespace Wisdom.Core
{
    /// <summary>
    /// 对象容器.
    /// </summary>
    public interface IObjectContainer : IServiceLocator, IServiceRegistrar, IServiceInjector, IDisposable
    {
        /// <summary>
        /// 通过application/web 配置文件初始化对象容器
        /// </summary>
        /// <param name="configSectionName">
        /// 通过在配置文件application/web中结点名称初始化对象容器</param>
        void InitializeFromConfigFile(string configSectionName);
        /// <summary>
        /// 获得源始容器实例
        /// </summary>
        /// <typeparam name="T">源容器类型.</typeparam>
        /// <returns>源容器实例</returns>
        T GetOriginalContainer<T>();
    }
}